3.1280 \(\int \frac {\tan ^{-1}(x) \log (1+x^2)}{x} \, dx\)

Optimal. Leaf size=189 \[ -\frac {1}{2} i \text {Li}_2(-i x) \left (-\log \left (x^2+1\right )+\log (1-i x)+\log (1+i x)\right )+\frac {1}{2} i \text {Li}_2(i x) \left (-\log \left (x^2+1\right )+\log (1-i x)+\log (1+i x)\right )-i \text {Li}_3(1-i x)+i \text {Li}_3(i x+1)+i \text {Li}_2(1-i x) \log (1-i x)-i \text {Li}_2(i x+1) \log (1+i x)+\frac {1}{2} i \log (i x) \log ^2(1-i x)-\frac {1}{2} i \log ^2(1+i x) \log (-i x) \]

[Out]

-1/2*I*ln(1+I*x)^2*ln(-I*x)+1/2*I*ln(1-I*x)^2*ln(I*x)+I*ln(1-I*x)*polylog(2,1-I*x)-I*ln(1+I*x)*polylog(2,1+I*x
)-1/2*I*(ln(1-I*x)+ln(1+I*x)-ln(x^2+1))*polylog(2,-I*x)+1/2*I*(ln(1-I*x)+ln(1+I*x)-ln(x^2+1))*polylog(2,I*x)-I
*polylog(3,1-I*x)+I*polylog(3,1+I*x)

________________________________________________________________________________________

Rubi [A]  time = 0.18, antiderivative size = 189, normalized size of antiderivative = 1.00, number of steps used = 12, number of rules used = 7, integrand size = 12, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.583, Rules used = {4848, 2391, 5011, 2396, 2433, 2374, 6589} \[ -\frac {1}{2} i \left (-\log \left (x^2+1\right )+\log (1-i x)+\log (1+i x)\right ) \text {PolyLog}(2,-i x)+\frac {1}{2} i \left (-\log \left (x^2+1\right )+\log (1-i x)+\log (1+i x)\right ) \text {PolyLog}(2,i x)-i \text {PolyLog}(3,1-i x)+i \text {PolyLog}(3,1+i x)+i \log (1-i x) \text {PolyLog}(2,1-i x)-i \log (1+i x) \text {PolyLog}(2,1+i x)+\frac {1}{2} i \log (i x) \log ^2(1-i x)-\frac {1}{2} i \log ^2(1+i x) \log (-i x) \]

Antiderivative was successfully verified.

[In]

Int[(ArcTan[x]*Log[1 + x^2])/x,x]

[Out]

(-I/2)*Log[1 + I*x]^2*Log[(-I)*x] + (I/2)*Log[1 - I*x]^2*Log[I*x] + I*Log[1 - I*x]*PolyLog[2, 1 - I*x] - I*Log
[1 + I*x]*PolyLog[2, 1 + I*x] - (I/2)*(Log[1 - I*x] + Log[1 + I*x] - Log[1 + x^2])*PolyLog[2, (-I)*x] + (I/2)*
(Log[1 - I*x] + Log[1 + I*x] - Log[1 + x^2])*PolyLog[2, I*x] - I*PolyLog[3, 1 - I*x] + I*PolyLog[3, 1 + I*x]

Rule 2374

Int[(Log[(d_.)*((e_) + (f_.)*(x_)^(m_.))]*((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.))/(x_), x_Symbol] :> -Sim
p[(PolyLog[2, -(d*f*x^m)]*(a + b*Log[c*x^n])^p)/m, x] + Dist[(b*n*p)/m, Int[(PolyLog[2, -(d*f*x^m)]*(a + b*Log
[c*x^n])^(p - 1))/x, x], x] /; FreeQ[{a, b, c, d, e, f, m, n}, x] && IGtQ[p, 0] && EqQ[d*e, 1]

Rule 2391

Int[Log[(c_.)*((d_) + (e_.)*(x_)^(n_.))]/(x_), x_Symbol] :> -Simp[PolyLog[2, -(c*e*x^n)]/n, x] /; FreeQ[{c, d,
 e, n}, x] && EqQ[c*d, 1]

Rule 2396

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_)/((f_.) + (g_.)*(x_)), x_Symbol] :> Simp[(Log[(e*
(f + g*x))/(e*f - d*g)]*(a + b*Log[c*(d + e*x)^n])^p)/g, x] - Dist[(b*e*n*p)/g, Int[(Log[(e*(f + g*x))/(e*f -
d*g)]*(a + b*Log[c*(d + e*x)^n])^(p - 1))/(d + e*x), x], x] /; FreeQ[{a, b, c, d, e, f, g, n, p}, x] && NeQ[e*
f - d*g, 0] && IGtQ[p, 1]

Rule 2433

Int[((a_.) + Log[(c_.)*((d_) + (e_.)*(x_))^(n_.)]*(b_.))^(p_.)*((f_.) + Log[(h_.)*((i_.) + (j_.)*(x_))^(m_.)]*
(g_.))*((k_.) + (l_.)*(x_))^(r_.), x_Symbol] :> Dist[1/e, Subst[Int[((k*x)/d)^r*(a + b*Log[c*x^n])^p*(f + g*Lo
g[h*((e*i - d*j)/e + (j*x)/e)^m]), x], x, d + e*x], x] /; FreeQ[{a, b, c, d, e, f, g, h, i, j, k, l, n, p, r},
 x] && EqQ[e*k - d*l, 0]

Rule 4848

Int[((a_.) + ArcTan[(c_.)*(x_)]*(b_.))/(x_), x_Symbol] :> Simp[a*Log[x], x] + (Dist[(I*b)/2, Int[Log[1 - I*c*x
]/x, x], x] - Dist[(I*b)/2, Int[Log[1 + I*c*x]/x, x], x]) /; FreeQ[{a, b, c}, x]

Rule 5011

Int[(ArcTan[(c_.)*(x_)]*Log[(f_.) + (g_.)*(x_)^2])/(x_), x_Symbol] :> Dist[Log[f + g*x^2] - Log[1 - I*c*x] - L
og[1 + I*c*x], Int[ArcTan[c*x]/x, x], x] + (Dist[I/2, Int[Log[1 - I*c*x]^2/x, x], x] - Dist[I/2, Int[Log[1 + I
*c*x]^2/x, x], x]) /; FreeQ[{c, f, g}, x] && EqQ[g, c^2*f]

Rule 6589

Int[PolyLog[n_, (c_.)*((a_.) + (b_.)*(x_))^(p_.)]/((d_.) + (e_.)*(x_)), x_Symbol] :> Simp[PolyLog[n + 1, c*(a
+ b*x)^p]/(e*p), x] /; FreeQ[{a, b, c, d, e, n, p}, x] && EqQ[b*d, a*e]

Rubi steps

\begin {align*} \int \frac {\tan ^{-1}(x) \log \left (1+x^2\right )}{x} \, dx &=\frac {1}{2} i \int \frac {\log ^2(1-i x)}{x} \, dx-\frac {1}{2} i \int \frac {\log ^2(1+i x)}{x} \, dx+\left (-\log (1-i x)-\log (1+i x)+\log \left (1+x^2\right )\right ) \int \frac {\tan ^{-1}(x)}{x} \, dx\\ &=-\frac {1}{2} i \log ^2(1+i x) \log (-i x)+\frac {1}{2} i \log ^2(1-i x) \log (i x)+\frac {1}{2} \left (i \left (\log (1-i x)+\log (1+i x)-\log \left (1+x^2\right )\right )\right ) \int \frac {\log (1+i x)}{x} \, dx+\frac {1}{2} \left (i \left (-\log (1-i x)-\log (1+i x)+\log \left (1+x^2\right )\right )\right ) \int \frac {\log (1-i x)}{x} \, dx-\int \frac {\log (1+i x) \log (-i x)}{1+i x} \, dx-\int \frac {\log (1-i x) \log (i x)}{1-i x} \, dx\\ &=-\frac {1}{2} i \log ^2(1+i x) \log (-i x)+\frac {1}{2} i \log ^2(1-i x) \log (i x)-\frac {1}{2} i \left (\log (1-i x)+\log (1+i x)-\log \left (1+x^2\right )\right ) \text {Li}_2(-i x)+\frac {1}{2} i \left (\log (1-i x)+\log (1+i x)-\log \left (1+x^2\right )\right ) \text {Li}_2(i x)+i \operatorname {Subst}\left (\int \frac {\log (-i (i-i x)) \log (x)}{x} \, dx,x,1+i x\right )-i \operatorname {Subst}\left (\int \frac {\log (i (-i+i x)) \log (x)}{x} \, dx,x,1-i x\right )\\ &=-\frac {1}{2} i \log ^2(1+i x) \log (-i x)+\frac {1}{2} i \log ^2(1-i x) \log (i x)+i \log (1-i x) \text {Li}_2(1-i x)-i \log (1+i x) \text {Li}_2(1+i x)-\frac {1}{2} i \left (\log (1-i x)+\log (1+i x)-\log \left (1+x^2\right )\right ) \text {Li}_2(-i x)+\frac {1}{2} i \left (\log (1-i x)+\log (1+i x)-\log \left (1+x^2\right )\right ) \text {Li}_2(i x)-i \operatorname {Subst}\left (\int \frac {\text {Li}_2(x)}{x} \, dx,x,1-i x\right )+i \operatorname {Subst}\left (\int \frac {\text {Li}_2(x)}{x} \, dx,x,1+i x\right )\\ &=-\frac {1}{2} i \log ^2(1+i x) \log (-i x)+\frac {1}{2} i \log ^2(1-i x) \log (i x)+i \log (1-i x) \text {Li}_2(1-i x)-i \log (1+i x) \text {Li}_2(1+i x)-\frac {1}{2} i \left (\log (1-i x)+\log (1+i x)-\log \left (1+x^2\right )\right ) \text {Li}_2(-i x)+\frac {1}{2} i \left (\log (1-i x)+\log (1+i x)-\log \left (1+x^2\right )\right ) \text {Li}_2(i x)-i \text {Li}_3(1-i x)+i \text {Li}_3(1+i x)\\ \end {align*}

________________________________________________________________________________________

Mathematica [F]  time = 0.78, size = 0, normalized size = 0.00 \[ \int \frac {\tan ^{-1}(x) \log \left (1+x^2\right )}{x} \, dx \]

Verification is Not applicable to the result.

[In]

Integrate[(ArcTan[x]*Log[1 + x^2])/x,x]

[Out]

Integrate[(ArcTan[x]*Log[1 + x^2])/x, x]

________________________________________________________________________________________

fricas [F]  time = 0.40, size = 0, normalized size = 0.00 \[ {\rm integral}\left (\frac {\arctan \relax (x) \log \left (x^{2} + 1\right )}{x}, x\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(arctan(x)*log(x^2+1)/x,x, algorithm="fricas")

[Out]

integral(arctan(x)*log(x^2 + 1)/x, x)

________________________________________________________________________________________

giac [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {\arctan \relax (x) \log \left (x^{2} + 1\right )}{x}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(arctan(x)*log(x^2+1)/x,x, algorithm="giac")

[Out]

integrate(arctan(x)*log(x^2 + 1)/x, x)

________________________________________________________________________________________

maple [C]  time = 2.80, size = 5237, normalized size = 27.71 \[ \text {output too large to display} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(arctan(x)*ln(x^2+1)/x,x)

[Out]

result too large to display

________________________________________________________________________________________

maxima [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {\arctan \relax (x) \log \left (x^{2} + 1\right )}{x}\,{d x} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(arctan(x)*log(x^2+1)/x,x, algorithm="maxima")

[Out]

integrate(arctan(x)*log(x^2 + 1)/x, x)

________________________________________________________________________________________

mupad [F]  time = 0.00, size = -1, normalized size = -0.01 \[ \int \frac {\ln \left (x^2+1\right )\,\mathrm {atan}\relax (x)}{x} \,d x \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((log(x^2 + 1)*atan(x))/x,x)

[Out]

int((log(x^2 + 1)*atan(x))/x, x)

________________________________________________________________________________________

sympy [F]  time = 0.00, size = 0, normalized size = 0.00 \[ \int \frac {\log {\left (x^{2} + 1 \right )} \operatorname {atan}{\relax (x )}}{x}\, dx \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(atan(x)*ln(x**2+1)/x,x)

[Out]

Integral(log(x**2 + 1)*atan(x)/x, x)

________________________________________________________________________________________